package com.shsh.safemanage.action;

import javax.servlet.http.HttpServletRequest;

import com.shsh.safemanage.dao.DaoCreator;
import com.shsh.safemanage.dao.UserDao;
import com.shsh.safemanage.util.Constants;

public class AdminAction {
	public boolean login(HttpServletRequest request) {
		String adminName = request.getParameter(Constants.REQUEST_PARAMETER_ADMIN_NAME);
		String password = request.getParameter(Constants.REQUEST_PARAMETER_PASSWORD);
		
		UserDao userDao = DaoCreator.createUserDao();
		return userDao.adminLogin(adminName, password);
	}
}
